﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace SerializeProject
{
    [Serializable]
    public class Test : List<Beverage>
    {
        public Test()
        {
            AddRange(new[] { 
                 new Beverage{ Name="Boga", IsAlcoholic = false, Price=12.3},
                 new Beverage{ Name="Boga", IsAlcoholic = false, Price=12.3},
                 new Beverage{ Name="Boga", IsAlcoholic = false, Price=12.3, Dummy =new Dummy{prop1="1", prop2=1}}
            });
        }
    }

    public class Person
    {
        public string FirstName { get; set; }
        public string FamilyName { get; set; }
        public int Age { get; set; }

        public override string ToString()
        {
            return string.Format("FirstName\":\"{0}\",\"" +
            "FamilyName\":\"{1}\",\"Age\": \"{2}",this.FirstName,
            this.FamilyName,
            this.Age);
        }

    }
}
